package main

import (
	"encoding/json"
	"log"
	"net-cfg-yang-parser/core/parser/huawei"
	"net-cfg-yang-parser/oc"
)

var dev = &oc.Device{}

func main() {

	parseHuaweiConfig()

}

func parseHuaweiConfig() {
	ruleFile := "./rule/huawei_rule.json"
	cfgFile := "./cfgfile/HUAWEI_interfaces.cfg"
	huawei.ParseCfgFile(ruleFile, cfgFile, dev)

	// 解析后的值
	s, _ := json.Marshal(dev)
	log.Printf("dev: %s", s)
}










